﻿using System;

using EnvDTE;

namespace Microsoft.WowAddonStudio.Automation
{
    public abstract class FileCodeModel : EnvDTE.FileCodeModel
    {
        private readonly DTE dte;
        private readonly ProjectItem parent;

        protected FileCodeModel(DTE dte, ProjectItem projectItem)
        {
            if (dte == null)
                throw new ArgumentNullException("dte");
            if (projectItem == null)
                throw new ArgumentNullException("projectItem");

            this.dte = dte;
            this.parent = projectItem;
        }

        public virtual DTE DTE
        {
            get { return dte; }
        }

        public virtual ProjectItem Parent
        {
            get { return parent; }
        }

        public abstract string Language { get; }
        public abstract EnvDTE.CodeElements CodeElements { get; }

        public virtual CodeNamespace AddNamespace(string Name, object Position)
        {
            throw new NotImplementedException();
        }

        public virtual CodeClass AddClass(string Name, object Position, object Bases, object ImplementedInterfaces, vsCMAccess Access)
        {
            throw new NotImplementedException();
        }

        public virtual CodeInterface AddInterface(string Name, object Position, object Bases, vsCMAccess Access)
        {
            throw new NotImplementedException();
        }

        public virtual CodeFunction AddFunction(string Name, vsCMFunction Kind, object Type, object Position, vsCMAccess Access)
        {
            throw new NotImplementedException();
        }

        public virtual CodeVariable AddVariable(string Name, object Type, object Position, vsCMAccess Access)
        {
            throw new NotImplementedException();
        }

        public virtual CodeAttribute AddAttribute(string Name, string Value, object Position)
        {
            throw new NotImplementedException();
        }

        public virtual CodeStruct AddStruct(string Name, object Position, object Bases, object ImplementedInterfaces, vsCMAccess Access)
        {
            throw new NotImplementedException();
        }

        public virtual CodeEnum AddEnum(string Name, object Position, object Bases, vsCMAccess Access)
        {
            throw new NotImplementedException();
        }

        public virtual CodeDelegate AddDelegate(string Name, object Type, object Position, vsCMAccess Access)
        {
            throw new NotImplementedException();
        }

        public abstract CodeElement CodeElementFromPoint(EnvDTE.TextPoint point, vsCMElement scope);
        public abstract void Remove(object Element);
    }
}